package com.service;

import java.util.List;
import com.pojo.Permission;

public interface IPermissionService {
	
	public Permission createPermission(Permission permission);

	public void deletePermission(int permissionId);

	/**
	 * 删除与它关联表的外键
	 * @param permissionId
	 */
	public void deletePermissions(int permissionId);

	/**
	 * 分页查询
	 * @param page 查询第几页
	 * @param groups 每组个数
	 * @return
	 */
	public List<Permission> getPermissions(int page,int groups);
	
	public List<Permission> getPermissions();

	public Permission getPermissionByid(int permissionid);

	public Permission updatePermission(Permission permission);
	
	/**
	 * 获取数据总数
	 * @return
	 */
	public int getCounts();

}
